package com.spzx.product.api;

import com.spzx.common.core.constant.SecurityConstants;
import com.spzx.common.core.constant.ServiceNameConstants;
import com.spzx.common.core.domain.R;
import com.spzx.product.api.domain.Brand;
import com.spzx.product.api.factory.RemoteBrandFallbackFactory;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestHeader;

import java.util.List;

/**
 * ClassName: RemoteBrandService
 * Package: com.spzx.product.api
 * Description:
 *
 * @Author 咚咚小圆帽
 * @Create 2025/3/16 20:58
 * @Version 1.0
 */
@FeignClient(
        contextId = "remoteBrandService",
        value = ServiceNameConstants.PRODUCT_SERVICE,
        fallbackFactory = RemoteBrandFallbackFactory.class
)
public interface RemoteBrandService {
    @GetMapping("/brand/getBrandAllList")
    R<List<Brand>> getBrandAllList(@RequestHeader(SecurityConstants.FROM_SOURCE) String source);
}
